package com.lottery.ruok.lottrey.adapter;

import android.content.Context;
import android.view.View;

import com.lottery.ruok.lottrey.retrofitModule.response.GetWholeCategoryResponse;
import com.lottery.ruok.lottrey.ui.component.HomeCPItemView;

public class HomeCPGridAdapter extends BaseListAdapter<GetWholeCategoryResponse.ItemsBean> {
    public HomeCPGridAdapter(Context context) {
        super(context);
    }

    @Override
    protected View createItemView(Context mContext) {
        return new HomeCPItemView(mContext);
    }

    @Override
    protected void onBindView(View itemView, int position) {
        if (itemView instanceof HomeCPItemView) {
            HomeCPItemView view = (HomeCPItemView) itemView;
            view.setData(getList().get(position));
        }
    }
}
